package com.tuanzi.loan.workflow.repository;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;

import com.tuanzi.loan.workflow.entity.ScriptTask;
import com.tuanzi.loan.workflow.entity.ScriptTaskType;

/**
 * @author Ray
 * @date 2018/01/12
 */
public interface ScriptTaskRepository extends JpaRepository<ScriptTask, Long> {

	List<ScriptTask> findAllByProcDefId(String procDefId);

	List<ScriptTask> findAllByProcDefIdAndActivityId(String procDefId, String activityId);

	ScriptTask findByProcDefIdAndActivityIdAndTaskType(String procDefId, String activityId, ScriptTaskType taskType);
}
